<script setup lang="ts">
import { useCounterStore } from "@/stores/counter";
// store中有状态和函数
const store = useCounterStore();
</script>

<template>
  <h1>状态管理</h1>
  <p>{{ store }}</p>
  <p>{{ store.doubleCount }}</p>
  <button @click="store.addCount(10)">stroe++</button>
</template>
